package com.example.demo11.controller

import com.example.demo11.controller.config.MyConfig
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.web.bind.annotation.{RequestMapping, RestController}

@RequestMapping(Array("/test"))
@RestController
class Hello2Controller {

  @Autowired
  private var myConfig:MyConfig = null

  @RequestMapping(Array("/config"))
  def getConfig:String = {
    myConfig.getServers.toString
  }
}
